import { createApp } from 'vue'
import App from './App.vue'

const app = createApp(App)
// 创建自定义指令
app.directive("color", {
    mounted(el, binding) {
        // 挂载时执行
        el.style.color=binding.value
    },
    updated(el, binding) {
        // 数据更新时执行
        el.style.color=binding.value
    }
})

// 渲染到指定位置
app.mount("#app")

